
#ifndef __MODELIO_UTIL_H
#define __MODELIO_UTIL_H

#include "MeshModel.h"

struct ModelIO_Util
{
	static bool LoadFile( const char* lpszFile, const char* lpszFormat, CMeshModel* pModel, int& mask, vcg::CallBackPos *cb=0 );
	static bool SaveFile( const char* lpszFile, const char* lpszFormat, CMeshModel* pModel, const int mask, vcg::CallBackPos *cb=0 );


	static bool	Vcg_ImportDat( const char* lpszFile, const char* lpszFormat, CMeshModel* pModel, vcg::CallBackPos *cb=0 );
	static bool Vcg_ImportFile( const char* lpszFile, const char* lpszFormat, CMeshModel* pModel, int& mask, vcg::CallBackPos *cb=0 );

private:
	static void InitOpenParameter( const char* format, CMeshModel* pModel );
	static void ApplyOpenParameter( const char* format, CMeshModel* pModel );
	static void InitPreOpenParameter( const char* formatName, const char* filename );
	static void InitSaveParameter( const char* format, CMeshModel* pModel );
};




#endif	//__MODELIO_UTIL_H
